/*
 * @Description: 
 * @Date: 2025-09-29 09:29:21
 * @LastEditTime: 2025-09-30 10:35:36
 */
import request from "../utils/request";

export function getPhone(data) {
    return request({
        url: "/busiluckmobile/queryAvailableByPattern",
        method: "post",
        data
    });
}

export function getOptionsByGroupCodes(groupCodes) {
    return request({
        url: `/groupitem/queryListByGroupCodes`,
        data: groupCodes,
        method: "post",
    });
}

export function occupy(mobile, occupyType, remark) {
    return request({
      url: `/busiluckmobileoccupy/add`,
      data: {
        code: 'occupy_time',
        mobile: mobile,
        type: occupyType,
        remark: remark
      },
      method: "post",
    });
  }

  export function getOccupiedLuckMobile(pageSize, pageIndex) {
    return request({
        url: `/busiluckmobileoccupy/occupyList?pageSize=${pageSize}&pageNum=${pageIndex}`,
        data: {
            code: 'occupy_time',
            isUserList: true
        },
        method: "post",
    });
}

export function applyById(id, mobile) {
    return request({
        url: `/busiluckmobileoccupy/applying`,
        data: {
            id: id,
            mobile: mobile
        },
        method: "post",
    });
}

export function getRichText(pageSize, pageIndex) {
    return request({
        url: `/businoticconfig/queryByCond?pageNum=${pageIndex}&pageSize=${pageSize}`,
        data: {},
        method: "post",
    });
}
